package com.moon.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import com.moon.utils.BaseController;

@Controller
public class HomeController extends BaseController {
	@RequestMapping("/")
	public String home() {
		return "tao/home";
	}

	@RequestMapping("/openWork/{work}")
	public String openWork(@PathVariable("work") String work) {
		return "tao/" + work;
	}
//	@RequestMapping("/page")
//	public String page() {
//		return "tao/page";
//	}
	@RequestMapping({ "/success", "/info" })
	public String success() {
		return "tao/success";
	}

	@RequestMapping("/login")
	public String login() {
		return "tao/login";
	}

//	@RequestMapping("/check")
//
//	@ResponseBody
//	public Object check(String mobile, String msg, HttpServletResponse resp) {
//		String api = "http://v.juhe.cn/sms/send?mobile=" + mobile + "&tpl_id=188494&tpl_value=%23code%23%3d" + msg
//				+ "&key=ff55f3176ca70a91101a31088836fba8";
//		Object obj = rest.getForObject(api, Object.class);
//		return obj;
//	}

}